package com.twu.biblioteca;

import com.twu.bean.User;
import com.twu.bean.UserList;

public class Login
{
	private static final String LOGIN = "Y";
	private final UserList userList;

	public Login()
	{
		userList = new UserList();
	}

	static boolean loginOrNot(String input)
	{
		return LOGIN.equals(input.toUpperCase());
	}

	public boolean isLogin(User inputUser)
	{
		return userList.isValid(inputUser);
	}

	public User getCurrentUser()
	{
		return userList.getCurrentUser();
	}

}
